package com.jdd.modules.project.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.jdd.modules.people.entity.PassagePeople;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.jdd.modules.project.entity.SysProject;
import org.apache.ibatis.annotations.Param;

/**
 * <p>
 * 用户表 Mapper 接口
 * </p>
 *
 * @author zly
 * @since 2022-03-15
 */

public interface SysProjectMapper extends BaseMapper<SysProject> {
    IPage<SysProject> getProjectPage(Page<SysProject> sysProjectIPage, @Param("sysProject") SysProject sysProject);

    /*删除用户权限*/
    void deleteRolePermission(@Param("sysProjectId") String sysProjectId);

    /*删除用户角色*/
    void deleteSysRole(@Param("sysProjectId") String sysProjectId);

    /*删除用户与角色的关联关系*/
    void deleteUserRole(@Param("sysProjectId") String sysProjectId);

    /*删除项目下角色权限*/
    void deleteSysRolePermission(@Param("sysProjectId") String sysProjectId);

    /*删除大区域关联关系*/
    void deleteSysDepartArea(@Param("sysProjectId") String sysProjectId);

    /*删除大区域*/
    void deleteDepartArea(@Param("sysProjectId") String sysProjectId);

    /*删除小区域*/
    void deleteTArea(@Param("sysProjectId") String sysProjectId);

    /*删除楼栋*/
    void deleteBuilding(@Param("sysProjectId") String sysProjectId);

    /*删除项目下的部门*/
    void deleteDepartment(@Param("sysProjectId") String sysProjectId);

    /*删除项目下的设备*/
    void deleteDevice(@Param("sysProjectId") String sysProjectId);

    /*删除项目下设备的配置信息*/
    void deleteDeviceConf(@Param("sysProjectId") String sysProjectId);

    /*删除楼层*/
    void deleteFloor(@Param("sysProjectId") String sysProjectId);

    /*删除房屋*/
    void deleteHouse(@Param("sysProjectId") String sysProjectId);


    /*删除项目下的人员类型*/
    void deleteUserType(@Param("sysProjectId") String sysProjectId);


    /*删除项目下的用户*/
    void deleteUser(@Param("sysProjectId") String sysProjectId);

    /*删除项目*/
    void deleteProject(@Param("sysProjectId") String sysProjectId);


    /*删除单元*/
    void deleteUnit(@Param("sysProjectId") String sysProjectId);

    /*删除user和device的绑定关系*/
    void deleteUserDevice(@Param("sysProjectId") String sysProjectId);

}
